home *** CD-ROM | disk | FTP | other *** search
- Path: news.erg.cuhk.hk!cslee
- From: cslee@cs.cuhk.hk (ERiC LEE)
- Newsgroups: comp.lang.c
- Subject: Special linked list
- Date: 7 Mar 1996 17:52:31 GMT
- Organization: Engineering Faculty CUHK
- Message-ID: <4hn7ov$e1t@eng_ser1.erg.cuhk.hk>
- NNTP-Posting-Host: sun9.cs.cuhk.hk
- X-Newsreader: TIN [version 1.2 PL2]
-
- Is there a method to build a linked list using struct & pointer,
- where the linked list (in fact a two-dimensional linked list, where for
- example, b3 has 2 pointers at b4 & a3, which is also pointed by b2 & c3)
- is as shown below? (All the data are long integers)
-
- a1 -> a2 -> a3 -> a4 -> ...
-
- ^ ^ ^ ^
- | | | |
-
- b1 -> b2 -> b3 -> b4 -> ...
-
- ^ ^ ^ ^
- | | | |
-
- c1 -> c2 -> c3 -> c4 -> ...
-
- ^ ^ ^ ^
- | | | |
-
- . . . .
- . . . .
- . . . .
-